package Models;

import java.util.Date;

import utils.Calcs;

public class FermentationFive {
    private double fermentationTemp;
    private double fermentationGravity;
    private Date fermentationDate;
    private Date fermentationTime;
    private String fermentationNotes;
    
    public FermentationFive(final double temp, final double grav, final java.util.Date date
            , final java.util.Date time, final String notes){
        super();
        this.fermentationTemp = temp;
        //this.fermentationGravity = grav;
        if(((double)grav < 1.200)&&(grav != 0)){
            this.fermentationGravity = (double)Calcs.specificGravityToPlato(grav);
        } else {
            this.fermentationGravity = grav;
        }
        this.fermentationDate = date;
        this.fermentationTime = time;
        this.fermentationNotes = notes;
    }
    
    public FermentationFive(){
        super();
    }
    
    public double getFermentationTemp(){
        return this.fermentationTemp;
    }
    public void setFermentationTemp(final double temp){
        this.fermentationTemp = temp;
    }
    
    public double getFermentationGravity(){
        return this.fermentationGravity;
    }
    public void setFermentationGravity(final double grav){
        if(((double)grav < 1.200)&&(grav != 0)){
            this.fermentationGravity = (float)Calcs.specificGravityToPlato(grav);
        } else {
            this.fermentationGravity = grav;
        }
    }
    
    public java.util.Date getFermentationDate(){
        return this.fermentationDate;
    }
    public void setDate(final java.util.Date date){
        this.fermentationDate = date;
    }
    
    public java.util.Date getFermentationTime(){
        return this.fermentationTime;
    }
    public void setFermentationTime(final java.util.Date time){
        this.fermentationTime = time;
    }
    
    public String getFermentationNotes(){
        return this.fermentationNotes;
    }
    public void setFermentationNotes(final String notes){
        this.fermentationNotes = notes;
    }

}
